xend: notify xenpv device model that console info is ready
authorKeir Fraser <keir.fraser@citrix.com>
Wed, 24 Feb 2010 09:38:35 +0000 (09:38 +0000)
committerKeir Fraser <keir.fraser@citrix.com>
Wed, 24 Feb 2010 09:38:35 +0000 (09:38 +0000)
commit078a073a6ccd4f6a66cce154ecaeceaa39c28b78
treeb93be4edf4355270cd7d3e316392695339e40c41
parent79e0b9479d3d37940fdbff83183daaeafacbe668
xend: notify xenpv device model that console info is ready

Sometimes PV domain with vfb doesn't boot up. /sbin/kudzu is stuck.
After investigation, I've found that the evtchn for console is not
bound at all.

Normal sequence of evtchn initialization in qemu-dm for xenpv is:
1) watch xenstore backpath (/local/domain/0/backend/console/<domid>/0)
2) read console info (/local/domain/<domid>/console/{type, ring-ref,
port..=
})
3) bind the evtchn to the port.

But in some case, xend writes to the backpath before the console info
is prepared, and never write to the backpath again. So the qemu-dm
fails at 2) and never reach to 3).

When this happens, manually xenstore-write command on Domain-0
resumes the guest.

Signed-off-by: Kouya Shimura <kouya@jp.fujitsu.com>
tools/python/xen/xend/XendDomainInfo.py